Get Account
'GetAccount' API enables to fetch the details of an account
Bank or financial institution can fetch all the available details of an account, if required. On providing the Account ID as request, all the available details of an account can be fetched out.
Method: POST
{{URL}}/jsonrpc
Example
Request Parameters
Parameter | Description |
---|---|
method Mandatory | String API method that is being called to get account details through account service Constant value: "AccountService.GetAccount" |
id Mandatory | String Unique ID of API request Sample value: "1" |
params Mandatory | Object |
api Mandatory | Object |
signature Mandatory | String Sign the request payload (params.payload) using private key. Sample value: "MEQCIAbpxHpdOyBEVlmxPYv7m4Z1OvWJJYw7g7u3GE3T9nmvAiBjKHckSvb1M6O4t7FeWsn2z9Y3dMeYn3HyX/k28ek/Dw==" |
keyId Mandatory | String Key ID is provided at the time of device registration. Sample value: "348076" |
credential Mandatory | String Basic (space) ("<Username>:<apiKey>") as Base64 encoded value to be provided Sample value: "Basic bmF2eWEubitlbXBAbmV0eGQuY29tOmY1OWIwY2NlOTU4ZTQ1YTc4MGVhZWIzYWVjOWVjZDAx" |
payload Mandatory | Object |
ID Mandatory | String Unique Account ID of the account for which the account details to be fetched Sample value: "40004" |
- cURL
- C#
- Go
- NodeJS
curl --location --globoff '{{URL}}/jsonrpc' \
--header 'Content-Type: application/json' \
--data '{"method":"AccountService.GetAccount","id":"1","params":{"api":{"signature":"{{signature}}","keyId":"{{ApplicationKeyId}}","credential":"{{Credential}}"},"payload":{"ID":"40004"}}}'
var options = new RestClientOptions("{{URL}}/jsonrpc")
{
MaxTimeout = -1,
};
var client = new RestClient(options);
var request = new RestRequest("", Method.Post);
request.AddHeader("Content-Type", "application/json");
var body = @"{
" + "\n" +
@" ""method"": ""AccountService.GetAccount"",
" + "\n" +
@" ""id"": ""1"",
" + "\n" +
@" ""params"": {
" + "\n" +
@" ""api"": {
" + "\n" +
@" ""signature"": ""{{signature}}"",
" + "\n" +
@" ""keyId"": ""{{ApplicationKeyId}}"",
" + "\n" +
@" ""credential"": ""{{Credential}}""
" + "\n" +
@" },
" + "\n" +
@" ""payload"": {
" + "\n" +
@" ""ID"": ""40004""
" + "\n" +
@" }
" + "\n" +
@" }
" + "\n" +
@"}";
request.AddStringBody(body, DataFormat.Json);
RestResponse response = await client.ExecuteAsync(request);
Console.WriteLine(response.Content);
package main
import (
"fmt"
"strings"
"net/http"
"io/ioutil"
)
func main() {
url := "{{URL}}/jsonrpc"
method := "POST"
payload := strings.NewReader(`{`+"
"+`
"method": "AccountService.GetAccount",`+"
"+`
"id": "1",`+"
"+`
"params": {`+"
"+`
"api": {`+"
"+`
"signature": "{{signature}}",`+"
"+`
"keyId": "{{ApplicationKeyId}}",`+"
"+`
"credential": "{{Credential}}"`+"
"+`
},`+"
"+`
"payload": {`+"
"+`
"ID": "40004"`+"
"+`
}`+"
"+`
}`+"
"+`
}`)
client := &http.Client {
}
req, err := http.NewRequest(method, url, payload)
if err != nil {
fmt.Println(err)
return
}
req.Header.Add("Content-Type", "application/json")
res, err := client.Do(req)
if err != nil {
fmt.Println(err)
return
}
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(string(body))
}
var https = require('follow-redirects').https;
var fs = require('fs');
var options = {
'method': 'POST',
'hostname': '{{URL}}',
'path': '/jsonrpc',
'headers': {
'Content-Type': 'application/json'
},
'maxRedirects': 20
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"method": "AccountService.GetAccount",
"id": "1",
"params": {
"api": {
"signature": "{{signature}}",
"keyId": "{{ApplicationKeyId}}",
"credential": "{{Credential}}"
},
"payload": {
"ID": "40004"
}
}
});
req.write(postData);
req.end();
Body
{
"method": "AccountService.GetAccount",
"id": "1",
"params": {
"api": {
"signature": "{{signature}}",
"keyId": "{{ApplicationKeyId}}",
"credential": "{{Credential}}"
},
"payload": {
"ID": "40004"
}
}
}
Response: 200
Response Parameters
Parameter | Description |
---|---|
id | String Unique ID of the API request Sample Value :"1" |
jsonrpc | String JSON-RPC protocol version used Sample Value :"2.0" |
result | Object |
account | Object |
id | String Unique ID of the account Sample Value : "18492004" |
name | String Account name Sample Value : "Same Ledger Account" |
number | String Account Number Sample Value : "200501916028116" |
nickName | String Nickname for the account Sample Value : "Same Ledger Account" |
createdDate | String Date when the account was created (ISO 8601 format) Sample Value : "2025-02-25T08:25:39.359Z" |
updatedDate | String Last updated timestamp of the account Sample Value : "2025-06-02T10:23:00.039Z" |
balance | Number Current available balance in the account Sample Value : 1276 |
debit | Boolean Indicates if debit is allowed Sample Value : false |
minimumBalance | Number Minimum balance required in the account Sample Value : 0 |
holdBalance | Number Amount on hold in the account Sample Value : 2300 |
subLedgerCode | String Code representing the subledger Sample Value : "SL_200" |
tags | Array of String Tags related to the account Sample Value : ["AccountLevel: DEFAULT"] |
final | Boolean Indicates if the account is final Sample Value : true |
parent.ID | String ID of the parent account Sample Value : "4451002" |
result.account.parent.code | String Code of the parent account Sample Value : "" |
result.account.parent.name | String Name of the parent account Sample Value : "Same Ledger PoolAccount" |
result.account.parent.number | String Account Number of the parent account Sample Value : "900568962876004" |
customerID | String Customer ID associated with the account Sample Value : "100000000045001" |
customerName | String Customer name Sample Value : "EnableForAllAccount Test" |
institutionName | String Name of the institution Sample Value : "XD Legder" |
accountCategory | String Category of the account Sample Value : "LIABILITY" |
accountType | String Type of account Sample Value : "SAVINGS" |
currency | String Currency code in ISO format Sample Value : "USD" |
currencyCode | String Numeric currency code Sample Value : "840" |
legalReps[].ID | String Legal representative ID Sample Value : "18335002" |
legalReps[].name | String Name of the legal representative Sample Value : "Raja" |
legalReps[].createdDate | String Creation date of legal rep record Sample Value : "0001-01-01T00:00:00Z" |
legalReps[].updatedDate | String Last update timestamp of legal rep record Sample Value : "0001-01-01T00:00:00Z" |
status | String Account status Sample Value : "ACTIVE" |
institutionID | String Institution ID Sample Value : "101115399" |
glAccount | String General Ledger account number Sample Value : "900568962876004" |
DDAAccount | Boolean Indicates if it's a DDA (Demand Deposit Account) Sample Value : true |
address.addressLine1 | String Address line 1 Sample Value : "No2" |
address.city | String City Sample Value : "US" |
address.state | String State Sample Value : "US" |
address.country | String Country Sample Value : "US" |
address.zip | String ZIP or postal code Sample Value : "64643" |
isVerify | Boolean Whether the account is verified Sample Value : true |
minimumRouteApprovers | Number Minimum Number of route approvers required Sample Value : 0 |
newRouteAlert | Boolean Whether there is a new route alert Sample Value : false |
ceTransactionNumber | String CE transaction reference number Sample Value : "PL18492005" |
accountLevel | String Account level indicator Sample Value : "DEFAULT" |
ledgerBalance | Number Ledger balance of the account Sample Value : 3576 |
preAuthBalance | Number Pre-authorized balance amount Sample Value : 0 |
accountFinderSync | Boolean Whether the account is synced with the account finder Sample Value : true |
isGLVerify | Boolean Whether GL verification is enabled Sample Value : false |
isShadowAccount | Boolean Indicates if it's a shadow account Sample Value : false |
sweep | Boolean Indicates if sweep is enabled Sample Value : false |
isClosed | Boolean Whether the account is closed Sample Value : false |
program | String Program ID associated with the account Sample Value : "100000000045001" |
productID | String Product ID (if any) |
externalLedger | Boolean Whether the account is linked to an external ledger Sample Value : false |
{
"id": "1",
"result": {
"account": {
"id": "18492004",
"name": "Same Ledger Account",
"number": "200501916028116",
"nickName": "Same Ledger Account",
"createdDate": "2025-02-25T08:25:39.359Z",
"updatedDate": "2025-06-02T10:23:00.039Z",
"balance": 1276,
"debit": false,
"minimumBalance": 0,
"holdBalance": 2300,
"subLedgerCode": "SL_200",
"tags": [
"AccountLevel: DEFAULT"
],
"final": true,
"parent": {
"ID": "4451002",
"code": "",
"name": "Same Ledger PoolAccount",
"number": "900568962876004"
},
"customerID": "100000000045001",
"customerName": "EnableForAllAccount Test",
"institutionName": "XD Legder",
"accountCategory": "LIABILITY",
"accountType": "SAVINGS",
"currency": "USD",
"currencyCode": "840",
"legalReps": [
{
"ID": "18335002",
"name": "Raja",
"createdDate": "0001-01-01T00:00:00Z",
"updatedDate": "0001-01-01T00:00:00Z"
}
],
"status": "ACTIVE",
"institutionID": "101115399",
"glAccount": "900568962876004",
"DDAAccount": true,
"address": {
"addressLine1": "No2",
"city": "US",
"state": "US",
"country": "US",
"zip": "64643"
},
"isVerify": true,
"minimumRouteApprovers": 0,
"newRouteAlert": false,
"ceTransactionNumber": "PL18492005",
"accountLevel": "DEFAULT",
"ledgerBalance": 3576,
"preAuthBalance": 0,
"accountFinderSync": true,
"isGLVerify": false,
"isShadowAccount": false,
"sweep": false,
"isClosed": false,
"program": "100000000045001",
"productID": "",
"externalLedger": false
}
},
"jsonrpc": "2.0"
}
Error Codes
Error Codes
Error Code | Error Message | Recommended Action |
---|---|---|
BAD_INPUT | ID is invalid or missing | "ID" is empty. Please provide a valid Account Id |
UNAUTHORIZED | Access Denied | Access Denied. Please Check with Support Team |
NOT_FOUND_ACCOUNT | Account doesn't exists | Account doesn't exists. Please provide a valid Account Id |
INVALID_SIGNATURE | Invalid Signature | Signature is invalid. Please ensure correct key, algorithm and signature process is followed |
NOT_FOUND_USER_DEVICE | User device not found | Invalid Key Id. please provide valid Key ID |
BAD_CREDENTIAL | Invalid Credential | Invalid credential. Please verify the credentials provided. |